package io.renren.modules.aic.entity;

import java.io.Serializable;
import java.util.Date;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;

/**
 * 价格走势表
 * 
 * @author chenshun
 * @email sunlightcs@gmail.com
 * @date 2018-04-16 23:59:55
 */
@TableName("tb_price_book")
public class PriceBookEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 主键
	 */
	@TableId
	private Long id;
	/**
	 * 开盘价
	 */
	@NotNull(message = "开盘价不能为空")
	@DecimalMin(value = "0.01", message = "开盘价最小为0.01")
	private Double openPrice;
	/**
	 * 收盘价
	 */
	@NotNull(message = "收盘价不能为空")
	@DecimalMin(value = "0.01", message = "收盘价最小为0.01")
	private Double closePrice;
	/**
	 * 最高价
	 */
	@NotNull(message = "最高价不能为空")
	@DecimalMin(value = "0.01", message = "最高价最小为0.01")
	private Double highPrice;
	/**
	 * 最低价
	 */
	@NotNull(message = "最低价不能为空")
	@DecimalMin(value = "0.01", message = "最低价最小为0.01")
	private Double lowPrice;
	/**
	 * 成交量
	 */
	@NotNull(message = "成交量不能为空")
	@Min(value = 1, message = "成交量最小为1")
	private Long vol;
	/**
	 * 幅度
	 */
	private Double rise;
	/**
	 * 创建时间
	 */
	private Date createTime;

	/**
	 * 设置：主键
	 */
	public void setId(Long id) {
		this.id = id;
	}

	/**
	 * 获取：主键
	 */
	public Long getId() {
		return id;
	}

	/**
	 * 设置：开盘价
	 */
	public void setOpenPrice(Double openPrice) {
		this.openPrice = openPrice;
	}

	/**
	 * 获取：开盘价
	 */
	public Double getOpenPrice() {
		return openPrice;
	}

	/**
	 * 设置：收盘价
	 */
	public void setClosePrice(Double closePrice) {
		this.closePrice = closePrice;
	}

	/**
	 * 获取：收盘价
	 */
	public Double getClosePrice() {
		return closePrice;
	}

	/**
	 * 设置：最高价
	 */
	public void setHighPrice(Double highPrice) {
		this.highPrice = highPrice;
	}

	/**
	 * 获取：最高价
	 */
	public Double getHighPrice() {
		return highPrice;
	}

	/**
	 * 设置：最低价
	 */
	public void setLowPrice(Double lowPrice) {
		this.lowPrice = lowPrice;
	}

	/**
	 * 获取：最低价
	 */
	public Double getLowPrice() {
		return lowPrice;
	}

	/**
	 * 设置：成交量
	 */
	public void setVol(Long vol) {
		this.vol = vol;
	}

	/**
	 * 获取：成交量
	 */
	public Long getVol() {
		return vol;
	}

	/**
	 * 设置：幅度
	 */
	public void setRise(Double rise) {
		this.rise = rise;
	}

	/**
	 * 获取：幅度
	 */
	public Double getRise() {
		return rise;
	}

	/**
	 * 设置：创建时间
	 */
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	/**
	 * 获取：创建时间
	 */
	public Date getCreateTime() {
		return createTime;
	}
}
